#include<iostream>
#include<cstring>
using namespace std;
int main()
{
	char arr[1100];
	int len = 0;
	while (fgets(arr,0,stdin))
	{
		len = strlen(arr);
		if (arr[0] >= 'a' && arr[0] <= 'z') {
			arr[0] -= 32;
		}
		for (int i = 1; i < len; i++) {
			if (arr[i] == ' ')
			{
				arr[i + 1] -= 32;
			}
		}
		for (int i = 0; i < len; i++) {
			cout << arr[i];
		}
		cout << endl;
	}
	return 0;
}
